//
//  ContentView.swift
//  XCUITestDemo
//
//  Created by  qitmac001420 on 2025/6/23.
//

import SwiftUI

struct ContentView: View {
    
    @State private var showAlert = false
    
    var body: some View {
        VStack {
            Image(systemName: "globe")
                .imageScale(.large)
                .foregroundStyle(.tint)
            Text("Hello, world!")
                .accessibilityIdentifier("hello-world-identifier")
            
            Button {
                showAlert = true
            } label: {
                Text("点我测试")
            }
            .accessibilityIdentifier("button-00")
            .alert(isPresented: $showAlert) {
                            Alert(
                                title: Text("Alert Title"),
                                message: Text("This is the alert message."),
                                dismissButton: .default(Text("OK"))
                            )
                        }

        }
        .padding()
    }
}

#Preview {
    ContentView()
}
